﻿@model IEnumerable<WebShop.Models.Basket>

@{
    ViewBag.Title = "Index";
}

<h2>Basket</h2>
<div>
    @using (Html.BeginForm("Create", "Order", FormMethod.Get))
    {
        @Html.AntiForgeryToken()
                <p>
            <input type="submit" value="Order items" />
        </p>
    }
</div>
<table>
    <tr>
        <th>
            Item Id
        </th>
        <th>
            Description
        </th>
        <th>
            UnitPrice
        </th>
        <th>
            Quantity
        </th>
        <th>
        </th>
    </tr>

@foreach (var item in Model) {
    <tr>
        <td>
            @Html.DisplayFor(modelItem => item.Item_Code)
        </td>
        <td>
            @Html.DisplayFor(modelItem => item.Item_Description)
        </td>
        <td>
            @Html.DisplayFor(modelItem => item.UnitPrice)
        </td>
        <td>
            @Html.DisplayFor(modelItem => item.Quantity)
        </td>
        <td>
            @Html.ActionLink("Edit", "Edit", new { id=item.Id }) |
            @Html.ActionLink("Details", "Details", new { id=item.Id }) |
            @Html.ActionLink("Delete", "Delete", new { id=item.Id })
        </td>
    </tr>
}

</table>
